package org.jeecg.modules.demo.weixin.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecg.modules.demo.weixin.dto.UserCardDto;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * @Description: 次卡用户表
 * @Author: jeecg-boot
 * @Date: 2023-10-28
 * @Version: V1.0
 */
@Data
@TableName("smt_once_card_users")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value = "smt_once_card_users对象", description = "smt_once_card_users")
public class SmtOnceCardUsers implements Serializable {
    private static final long serialVersionUID = 1L;

    /**
     * 次卡id
     */
    @Excel(name = "次卡id", width = 15)
    @ApiModelProperty(value = "次卡id")
    @TableId(type = IdType.AUTO)
    private Integer cardId;
    /**
     * 用户id
     */
    @Excel(name = "用户id", width = 15)
    @ApiModelProperty(value = "用户id")
    private Integer userId;
    /**
     * 用户昵称
     */
    @Excel(name = "用户昵称", width = 15)
    @ApiModelProperty(value = "用户昵称")
    private String userNickname;
    /**
     * 设备号
     */
    @Excel(name = "设备号", width = 15)
    @ApiModelProperty(value = "设备号")
    private String devCode;
    /**
     * 设备名称
     */
    @Excel(name = "设备名称", width = 15)
    @ApiModelProperty(value = "设备名称")
    private String devName;
    /**
     * 次卡名称
     */
    @Excel(name = "次卡名称", width = 15)
    @ApiModelProperty(value = "次卡名称")
    private String cardName;
    /**
     * 次卡卡号
     */
    @Excel(name = "次卡卡号", width = 15)
    @ApiModelProperty(value = "次卡卡号")
    private String cardNumber;
    /**
     * 次卡剩余次数
     */
    @Excel(name = "次卡剩余次数", width = 15)
    @ApiModelProperty(value = "次卡剩余次数")
    private Integer cardRest;
    /**
     * 次卡有效期
     */
    @Excel(name = "次卡有效期", width = 15)
    @ApiModelProperty(value = "次卡有效期")
    private String cardValidDate;
    /**
     * 创建时间
     */
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "创建时间")
    private Date createTime;
    /**
     * 更新时间
     */
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "更新时间")
    private Date updateTime;
    /**
     * 商户id
     */
    @Excel(name = "商户id", width = 15)
    @ApiModelProperty(value = "商户id")
    private Integer merchantId;
    /**
     * 商户名称
     */
    @Excel(name = "商户名称", width = 15)
    @ApiModelProperty(value = "商户名称")
    private String merName;

    /**
     * 卡总数
     */
    @Excel(name = "卡总数", width = 15)
    @ApiModelProperty(value = "卡总数")
    private Long cardTotal;

    /**
     * 订单id
     */
    @Excel(name = "订单id", width = 15)
    @ApiModelProperty(value = "订单id")
    private Integer orderId;

    /**
     * 次卡数量
     */
    @Excel(name = "次卡数量", width = 15)
    @ApiModelProperty(value = "次卡数量")
    private Integer productNum;
    /**
     * 商品id
     */
    @Excel(name = "商品id", width = 15)
    @ApiModelProperty(value = "商品id")
    private String goodsId;
    /**
     * 次卡code /次卡商品id
     */
    @Excel(name = "次卡code /次卡商品id", width = 15)
    @ApiModelProperty(value = "次卡code /次卡商品id")
    private Integer cardCode;

    /**
     * 订单商品list
     */
    @TableField(exist = false)
    private List<UserCardDto> userCardDtoList;
    /**
     * 商户id
     */
    @TableField(exist = false)
    private String merId;

    /**
     * 商品名称
     */
    @TableField(exist = false)
    private String goodName;
}
